<template>
  <div class="placeholder-page">
    <div class="placeholder-content">
      <el-icon class="placeholder-icon" size="64">
        <Document />
      </el-icon>
      <h2 class="placeholder-title">{{ title }}</h2>
      <p class="placeholder-description">该页面正在开发中，敬请期待...</p>
    </div>
  </div>
</template>

<script setup lang="ts">
import { Document } from '@element-plus/icons-vue'
import { useRoute } from 'vue-router'
import { computed } from 'vue'

const route = useRoute()

const title = computed(() => {
  return route.meta?.title || '页面开发中'
})
</script>

<style scoped>
.placeholder-page {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 400px;
  background-color: #f5f7fa;
}

.placeholder-content {
  text-align: center;
  padding: 40px;
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
}

.placeholder-icon {
  color: #909399;
  margin-bottom: 20px;
}

.placeholder-title {
  color: #303133;
  margin-bottom: 16px;
  font-size: 20px;
  font-weight: 500;
}

.placeholder-description {
  color: #606266;
  font-size: 14px;
  margin: 0;
}
</style>